﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data;

namespace Deeper.DataAccess
{


	/// <summary>
	/// 执行SQL语句或存储过程的参数
	/// </summary>
	public class MyDbParams
	{
		/// <summary>
		/// 数据库字段类型
		/// </summary>
		public DbType DbType { get; set; }
		/// <summary>
		/// 参数性质
		/// </summary>
		public ParameterDirection Direction { set; get; }
		/// <summary>
		/// 是否可为空
		/// </summary>
		public bool IsNullable { get; set; }
		/// <summary>
		/// 参数名称
		/// </summary>
		public string ParameterName { get; set; }
		/// <summary>
		/// 参数字节大小
		/// </summary>
		public int Size { get; set; }
		/// <summary>
		/// 参数值
		/// </summary>
		public object Value { get; set; }
		/// <summary>
		/// 构造函数
		/// </summary>
		public MyDbParams(string pName = null, object pValue = null)
		{
			this.ParameterName = pName;
			this.Value = pValue;
			Direction = ParameterDirection.Input;
		}
	}
}
